{// 引入标签库 }
<tagLib name="html" />
<include file="Public:header" />
<load href='__TMPL__Common/js/jquery.bgiframe.js' />
<load href='__TMPL__Common/js/jquery.weebox.js' />
<load href='__TMPL__Common/js/user.js' />
<load href='__TMPL__Common/style/weebox.css' />
<div class="main">
<div class="main_title"><if condition="$order_info['order_status'] eq 0">{%DEAL_ORDER_HANDLE}<else />{%DEAL_ORDER_VIEW}</if>{$order_info.order_sn}

</div>
<script type="text/javascript">
	function viewDaodaBox(id){
		$.weeboxs.open(ROOT+'?m=SupplierLocationOrder&a=daodabox&id='+id, {contentType:'ajax',showButton:false,title:"撤销订单",width:400,height:100});
	}
	function viewCancelBox(id){
		$.weeboxs.open(ROOT+'?m=SupplierLocationOrder&a=cancelbox&id='+id, {contentType:'ajax',showButton:false,title:"撤销订单",width:500,height:160});
	}
</script>
<div class="blank5"></div>

<table class="form" cellpadding=0 cellspacing=0>
	<tr>
		<td colspan=4 class="topTd"></td>
	</tr>
	<tr>
		<td class="item_title">{%ORDER_USER}:</td>
		<td colspan="3" class="item_input">
			{$order_info.user_id|get_user_name_js}
		</td>
	</tr>
	<tr>
		<td class="item_title">{%ORDER_SN}:</td>
		<td colspan="3" class="item_input">{$order_info.order_sn}</td>
	</tr>	
	<tr>
		<td class="item_title">订单状态:</td>
		<td colspan="3" class="item_input">{$order_info.status|get_order_status=$order_info['deal_type']}
			<if condition="$order_info['order_money']&& $order_info['status'] eq 2">&nbsp;&nbsp;消费金额:{$order_info.order_money}</if>
			<if condition="$order_info['order_tip'] && $order_info['status'] eq 4">失败原因：{$order_info.order_tip}</if>
		</td>
	</tr>
	<tr>
	  <td class="item_title"><if condition="$order_info['deal_type'] eq 1">K歌<else/>就餐</if>时间：</td>
	  <td class="item_input">{$order_info.order_time|to_date='Y年m月d日 H点i分'}</td>
	  <td class="item_title">下单时间： </td>
	  <td class="item_input">{$order_info.create_time|to_date}</td>
  </tr>
  <tr>
		<td class="item_title">包房需求：:</td>
		<td colspan="3" class="item_input">
			<php>
				if ($order_info['deal_type'] == 1){
			</php>
				<if condition="$order_info['seat_status'] eq 0" >
				小包厢
				<elseif condition="$order_info['seat_status'] eq 1" />
				中包厢
				<elseif condition="$order_info['seat_status'] eq 2" />
				大包厢
				<elseif condition="$order_info['seat_status'] eq 3" />
				VIP包厢
				</if>
			<php>
				}
				else
				{
			</php>
				<if condition="$order_info['seat_status'] eq 0">只订大厅<else />包厢<php>if ($order_info['seat_switch'] == 0){</php>(订不到包房就订大厅)<php>}</php></if>
				<if condition="$order_info['extra_serve'] eq 1">
				<span class="ml10">吸烟区</span>
				<elseif condition="$order_info['extra_serve'] eq 2"/>
				<span class="ml10">无烟区</span>
				</if>
				<span class="ml10">
	            	接受最低消费：
					<if condition="$order_info['min_expense'] eq 500">
					500元以内
					<elseif condition="$order_info['min_expense'] eq 1000"/>
					501元-1000元
					<elseif condition="$order_info['min_expense'] eq 2000"/>
					1001元-2000元
					<elseif condition="$order_info['min_expense'] eq 5000"/>
					2001元-5000元
					<else/>
					无
					</if>
				</span>
			<php>
				}
			</php>
		</td>
	</tr>
	<tr>
		<td class="item_title">人数：</td>
		<td class="item_input" colspan="3">
			{$order_info.order_nums}<br>
		</td>
	</tr>
	
	<tr>
		<td rowspan="2" class="item_title">预订者信息：</td>
		<td class="item_input" colspan="3">
			手机:{$order_info.order_tel}
		</td>
	</tr>
	<tr>
		<td class="item_input" colspan="3">
			姓名:{$order_info.order_name} <if condition="$order_info['order_sex'] eq 1">先生<else/>女士</if>
		</td>									
	</tr>
	
	<tr>
		<td rowspan="2" class="item_title" >其他预订者信息：</td>
		<td class="item_input" colspan="3">
			手机:<if condition="$order_info['order_other_tel']">{$order_info.order_other_tel}<else/>无</if>
		</td>
	</tr>
	<tr>
		<td class="item_input" colspan="3">
			姓名:<if condition="$order_info['order_other_name']">{$order_info.order_other_name} <php>if ($order['order_other_sex'] == 1){ echo "先生"; }elseif($order['order_other_sex'] == 0){ echo "女士";}else{echo "公司";}</php><else/>无</if>
		</td>									
	</tr>
							
	<tr>
		<td class="item_title" >
		其他信息：									
		</td>									
		<td style="text-align: left;" class="item_input" colspan="3">
		{$order_info.order_msg}
		</td>
	</tr>
	
	<tr>
		<td class="item_title">订单操作</td>
		<td colspan="3" class="item_input">
			<php>
				if(get_gmtime() - $order_info['order_time'] < (24*3600)){
			</php>
				<if condition="$order_info['status'] eq 0">
				<input type="button" class="button" value="等待<if condition="$order_info['deal_type'] eq 1">K歌<else/>就餐</if>" onclick="location.href='__APP__?m=SupplierLocationOrder&a=step1&id={$order_info.id}';"  />
				</if>
				<if condition="$order_info['status'] eq 1">
				<input type="button" class="button" value="<if condition="$order_info['deal_type'] eq 1">K歌<else/>就餐</if>到达" onclick="viewDaodaBox({$order_info.id});"  />
				</if>
			<php>
				}
			</php>
			<if condition="$order_info['status'] lt 2">
				<input type="button" class="button" value="撤销订单" onclick="viewCancelBox({$order_info.id});"  />
			</if>
			<input type="button" class="button" value="返回订单列表"  onclick="location.href='__APP__?m=SupplierLocationOrder&a=index';"  />
		</td>
	</tr>
	<tr>
		<td colspan=4 class="bottomTd"></td>
	</tr>
</table>
<div class="blank5"></div>
</div>
<include file="Public:footer" />